import request from "../utils/request";

//条件分页查询
export const queryStocktaking = (page, pageSize, id) => {return request.get(`/stocktaking?page=${page}&pageSize=${pageSize}&id=${id}`)};

//添加数据
export const addStocktaking = (data) => {return request.post(`/stocktaking`,data)};

//回显数据
export const queryStocktakingById = (id) => {return request.get(`/stocktaking/${id}`)};

//删除
export const deleteStocktaking = (id) => {return request.delete(`/stocktaking/${id}`)};

//修改数据
export const updateStocktaking = (data) => {return request.put(`/stocktaking`,data)};

//修改报损数据
export const updateLossCount = (data) => {return request.put(`/stocktaking/loss`,data)};